--------------------------------------------------------------------------------
--!	@file	test1.lua
--!	@brief
--!		factorial test
--!
--!	@Description
--!		This program demonstrates a recursive function calls
--!		I/O and the "commenting trick"
--!
--!	Creation Date:	3/3/2013
--!
--!	$Id: test1.lua 170 2013-03-12 05:01:32Z ac.verbeck@gmail.com $
--------------------------------------------------------------------------------

-- defines a factorial function
---[[
function fact (n)
  if n == 0 then
	return 1
  else
	return n * fact(n-1)
  end
end

io.write("enter a number: ")
a = io.read("*number")        -- read a number
print(fact(a))
--]]
